package com.wyc.serviceorder.feign;

import com.wyc.internalCommon.response.TerminalResponse;
import com.wyc.internalCommon.response.TrSearchResponse;
import com.wyc.internalCommon.result.ApiResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient("service-map")
public interface ServiceMapFeignClient {

    /**
     * 搜索周边终端
     * @param center
     * @param radius
     * @return
     */
    @RequestMapping("/terminal/aroundSearch")
    ApiResult<List<TerminalResponse>> aroundSearch(@RequestParam("center") String center, @RequestParam("radius") Integer radius);

    /**
     * 查询轨迹信息
     * @param tid
     * @param starttime
     * @param endtime
     * @return
     */
    @RequestMapping("/terminal/trsearch")
    ApiResult<TrSearchResponse> trsearch(@RequestParam("tid") String tid, @RequestParam("starttime") Long starttime, @RequestParam("endtime") Long endtime);


    }
